package com.ruoyi.framework.web.service;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.env.Environment;
import org.springframework.stereotype.Service;

/**
 * @Author alison
 * @Date 2024/12/20 4:07
 * @Version 1.0
 * @Description
 */
@Slf4j
@Service("envService")
public class EnvrionmentService {


    @Autowired
    private Environment envrionment;

    public String getKey(String configKey) {
        String property = envrionment.getProperty(configKey);
        log.info("property: {}", property);
        return envrionment.getProperty(configKey);
    }
}
